package itesm.coler.models;

import java.io.Serializable;

import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;

@SuppressWarnings("serial")
@XmlRootElement(name = "user")
public class Autenticator implements Serializable {
	
	User user;
	
	public Autenticator(){	
	}
	
	public Autenticator(User user){
		this.user = user;
	}
	
	public void setAutenticator(User ble){
		user = ble;
	}
	
	@XmlElement
	public String getUsername(){
		return user.getUserName();
	}
	
	
	@XmlElement
	public String getAuthk(){
		return user.getPassword();
	}
	
	@XmlElement
	public String getUserType(){
		return user.getUserType();
	}
	@XmlElement
	public String getState(){
		if(user.isActive()){
			return "true";
		}
		return "false";
	}
	
}
